﻿using System;
using EkStudio.com.bean.xml.RootInterface;
using EkStudio.com.bean.xml.reflection;

namespace EkStudio.com.bean.xml.WorkFlow
{
    /// <summary>
    /// 工作流对模块状态限制功能
    /// </summary>
    public class WflowLimitElement: BillObjectInterface
    {
        private bool printBeforeStart = false;//启动前允许打印操作
        private bool printInprocess = true;//审批过程允许打印操作
        private bool attchInprocess = false;//审批过程允许附件操作

        [Xml]
        public bool PrintBeforeStart
        {
            get
            {
                return printBeforeStart;
            }

            set
            {
                printBeforeStart = value;
            }
        }
        [Xml]
        public bool PrintInprocess
        {
            get
            {
                return printInprocess;
            }

            set
            {
                printInprocess = value;
            }
        }
        [Xml]
        public bool AttchInprocess
        {
            get
            {
                return attchInprocess;
            }

            set
            {
                attchInprocess = value;
            }
        }
        [XmlTransient]
        public object ParentBean
        {
            get
            {
                throw new NotImplementedException();
            }

            set
            {
                throw new NotImplementedException();
            }
        }

        public object Clone()
        {
            WflowLimitElement clone = new WflowLimitElement();
            clone.AttchInprocess = attchInprocess;
            clone.PrintBeforeStart = printBeforeStart;
            clone.PrintInprocess = printInprocess;

            return clone;
        }
    }
}
